class AgendaController < ApplicationController

  before_filter :get_nav_categories
  before_filter :get_regions
  
  def index
    @article = Article.ez_find(:first) do |article|
      article.published == 1
      article.permalink == "agenda"
    end
    
    if @article.nil? then
      flash[:warning] = "page not found"
    else
      @page_title << " - #{@article.title}" unless @article.nil?
    end   
  end


	def mailer
    return unless request.post?
    message = params[:message]
    send_email(message)
    flash[:notice] = "Votre message a été envoyé correctement."
    redirect_to :action => :index
  end
	
end
